{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 46,
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import pandas as pd\n",
    "from sklearn import tree\n",
    "from sklearn.tree import DecisionTreeRegressor\n",
    "from sklearn.ensemble import RandomForestRegressor,GradientBoostingRegressor\n",
    "from sklearn.model_selection import cross_val_score,train_test_split,GridSearchCV\n",
    "from xgboost import XGBRegressor,XGBRFRegressor"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "      <th>target</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.566</td>\n",
       "      <td>0.016</td>\n",
       "      <td>-0.143</td>\n",
       "      <td>0.407</td>\n",
       "      <td>0.452</td>\n",
       "      <td>-0.901</td>\n",
       "      <td>-1.812</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>-0.436</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>0.327</td>\n",
       "      <td>-4.627</td>\n",
       "      <td>-4.789</td>\n",
       "      <td>-5.101</td>\n",
       "      <td>-2.608</td>\n",
       "      <td>-3.508</td>\n",
       "      <td>0.175</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.968</td>\n",
       "      <td>0.437</td>\n",
       "      <td>0.066</td>\n",
       "      <td>0.566</td>\n",
       "      <td>0.194</td>\n",
       "      <td>-0.893</td>\n",
       "      <td>-1.566</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.332</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.128</td>\n",
       "      <td>0.124</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.335</td>\n",
       "      <td>-0.730</td>\n",
       "      <td>0.676</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1.013</td>\n",
       "      <td>0.568</td>\n",
       "      <td>0.235</td>\n",
       "      <td>0.370</td>\n",
       "      <td>0.112</td>\n",
       "      <td>-0.797</td>\n",
       "      <td>-1.367</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.396</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>0.361</td>\n",
       "      <td>0.277</td>\n",
       "      <td>-0.116</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.765</td>\n",
       "      <td>-0.589</td>\n",
       "      <td>0.633</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.733</td>\n",
       "      <td>0.368</td>\n",
       "      <td>0.283</td>\n",
       "      <td>0.165</td>\n",
       "      <td>0.599</td>\n",
       "      <td>-0.679</td>\n",
       "      <td>-1.200</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.403</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.015</td>\n",
       "      <td>0.417</td>\n",
       "      <td>0.279</td>\n",
       "      <td>0.603</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.065</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.333</td>\n",
       "      <td>-0.112</td>\n",
       "      <td>0.206</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.684</td>\n",
       "      <td>0.638</td>\n",
       "      <td>0.260</td>\n",
       "      <td>0.209</td>\n",
       "      <td>0.337</td>\n",
       "      <td>-0.454</td>\n",
       "      <td>-1.073</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.314</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.183</td>\n",
       "      <td>1.078</td>\n",
       "      <td>0.328</td>\n",
       "      <td>0.418</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.215</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.280</td>\n",
       "      <td>-0.028</td>\n",
       "      <td>0.384</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2883</th>\n",
       "      <td>0.190</td>\n",
       "      <td>-0.025</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.161</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>0.757</td>\n",
       "      <td>0.584</td>\n",
       "      <td>-0.026</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.128</td>\n",
       "      <td>-0.208</td>\n",
       "      <td>0.809</td>\n",
       "      <td>-0.173</td>\n",
       "      <td>0.247</td>\n",
       "      <td>-0.027</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.686</td>\n",
       "      <td>0.235</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2884</th>\n",
       "      <td>0.507</td>\n",
       "      <td>0.557</td>\n",
       "      <td>0.296</td>\n",
       "      <td>0.183</td>\n",
       "      <td>0.530</td>\n",
       "      <td>-0.237</td>\n",
       "      <td>0.749</td>\n",
       "      <td>0.584</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.287</td>\n",
       "      <td>0.465</td>\n",
       "      <td>-0.310</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>1.042</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2885</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.721</td>\n",
       "      <td>-0.485</td>\n",
       "      <td>0.084</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.034</td>\n",
       "      <td>0.655</td>\n",
       "      <td>0.614</td>\n",
       "      <td>-0.818</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.268</td>\n",
       "      <td>0.552</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.951</td>\n",
       "      <td>0.748</td>\n",
       "      <td>0.005</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2886</th>\n",
       "      <td>-0.219</td>\n",
       "      <td>-0.282</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.449</td>\n",
       "      <td>-0.140</td>\n",
       "      <td>0.560</td>\n",
       "      <td>0.583</td>\n",
       "      <td>-0.596</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.216</td>\n",
       "      <td>1.061</td>\n",
       "      <td>-0.051</td>\n",
       "      <td>1.023</td>\n",
       "      <td>0.878</td>\n",
       "      <td>0.610</td>\n",
       "      <td>-0.230</td>\n",
       "      <td>-0.301</td>\n",
       "      <td>0.555</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2887</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.379</td>\n",
       "      <td>0.092</td>\n",
       "      <td>0.550</td>\n",
       "      <td>0.551</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.047</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>0.847</td>\n",
       "      <td>0.534</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>-0.190</td>\n",
       "      <td>-0.567</td>\n",
       "      <td>0.388</td>\n",
       "      <td>0.417</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>2888 rows × 39 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "0     0.566  0.016 -0.143  0.407  0.452 -0.901 -1.812 -2.360 -0.436 -2.114   \n",
       "1     0.968  0.437  0.066  0.566  0.194 -0.893 -1.566 -2.360  0.332 -2.114   \n",
       "2     1.013  0.568  0.235  0.370  0.112 -0.797 -1.367 -2.360  0.396 -2.114   \n",
       "3     0.733  0.368  0.283  0.165  0.599 -0.679 -1.200 -2.086  0.403 -2.114   \n",
       "4     0.684  0.638  0.260  0.209  0.337 -0.454 -1.073 -2.086  0.314 -2.114   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  0.190 -0.025 -0.138  0.161  0.600 -0.212  0.757  0.584 -0.026  0.904   \n",
       "2884  0.507  0.557  0.296  0.183  0.530 -0.237  0.749  0.584  0.537  0.904   \n",
       "2885 -0.394 -0.721 -0.485  0.084  0.136  0.034  0.655  0.614 -0.818  0.904   \n",
       "2886 -0.219 -0.282 -0.344 -0.049  0.449 -0.140  0.560  0.583 -0.596  0.904   \n",
       "2887  0.368  0.380 -0.225 -0.049  0.379  0.092  0.550  0.551  0.244  0.904   \n",
       "\n",
       "      ...    V29    V30    V31    V32    V33    V34    V35    V36    V37  \\\n",
       "0     ...  0.136  0.109 -0.615  0.327 -4.627 -4.789 -5.101 -2.608 -3.508   \n",
       "1     ... -0.128  0.124  0.032  0.600 -0.843  0.160  0.364 -0.335 -0.730   \n",
       "2     ... -0.009  0.361  0.277 -0.116 -0.843  0.160  0.364  0.765 -0.589   \n",
       "3     ...  0.015  0.417  0.279  0.603 -0.843 -0.065  0.364  0.333 -0.112   \n",
       "4     ...  0.183  1.078  0.328  0.418 -0.843 -0.215  0.364 -0.280 -0.028   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  ...  0.128 -0.208  0.809 -0.173  0.247 -0.027 -0.349  0.576  0.686   \n",
       "2884  ...  0.291 -0.287  0.465 -0.310  0.763  0.498 -0.349 -0.615 -0.380   \n",
       "2885  ...  0.291 -0.179  0.268  0.552  0.763  0.498 -0.349  0.951  0.748   \n",
       "2886  ...  0.216  1.061 -0.051  1.023  0.878  0.610 -0.230 -0.301  0.555   \n",
       "2887  ...  0.047  0.057 -0.042  0.847  0.534 -0.009 -0.190 -0.567  0.388   \n",
       "\n",
       "      target  \n",
       "0      0.175  \n",
       "1      0.676  \n",
       "2      0.633  \n",
       "3      0.206  \n",
       "4      0.384  \n",
       "...      ...  \n",
       "2883   0.235  \n",
       "2884   1.042  \n",
       "2885   0.005  \n",
       "2886   0.350  \n",
       "2887   0.417  \n",
       "\n",
       "[2888 rows x 39 columns]"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "train_data = pd.read_csv('zhengqi_train.txt',sep='\\t')\n",
    "train_data"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "train1 = train_data.sample(n=)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "      <th>target</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.566</td>\n",
       "      <td>0.016</td>\n",
       "      <td>-0.143</td>\n",
       "      <td>0.407</td>\n",
       "      <td>0.452</td>\n",
       "      <td>-0.901</td>\n",
       "      <td>-1.812</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>-0.436</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>0.327</td>\n",
       "      <td>-4.627</td>\n",
       "      <td>-4.789</td>\n",
       "      <td>-5.101</td>\n",
       "      <td>-2.608</td>\n",
       "      <td>-3.508</td>\n",
       "      <td>0.175</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.968</td>\n",
       "      <td>0.437</td>\n",
       "      <td>0.066</td>\n",
       "      <td>0.566</td>\n",
       "      <td>0.194</td>\n",
       "      <td>-0.893</td>\n",
       "      <td>-1.566</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.332</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.128</td>\n",
       "      <td>0.124</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.335</td>\n",
       "      <td>-0.730</td>\n",
       "      <td>0.676</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1.013</td>\n",
       "      <td>0.568</td>\n",
       "      <td>0.235</td>\n",
       "      <td>0.370</td>\n",
       "      <td>0.112</td>\n",
       "      <td>-0.797</td>\n",
       "      <td>-1.367</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.396</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>0.361</td>\n",
       "      <td>0.277</td>\n",
       "      <td>-0.116</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.765</td>\n",
       "      <td>-0.589</td>\n",
       "      <td>0.633</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.733</td>\n",
       "      <td>0.368</td>\n",
       "      <td>0.283</td>\n",
       "      <td>0.165</td>\n",
       "      <td>0.599</td>\n",
       "      <td>-0.679</td>\n",
       "      <td>-1.200</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.403</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.015</td>\n",
       "      <td>0.417</td>\n",
       "      <td>0.279</td>\n",
       "      <td>0.603</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.065</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.333</td>\n",
       "      <td>-0.112</td>\n",
       "      <td>0.206</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.684</td>\n",
       "      <td>0.638</td>\n",
       "      <td>0.260</td>\n",
       "      <td>0.209</td>\n",
       "      <td>0.337</td>\n",
       "      <td>-0.454</td>\n",
       "      <td>-1.073</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.314</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.183</td>\n",
       "      <td>1.078</td>\n",
       "      <td>0.328</td>\n",
       "      <td>0.418</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.215</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.280</td>\n",
       "      <td>-0.028</td>\n",
       "      <td>0.384</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2095</th>\n",
       "      <td>-1.767</td>\n",
       "      <td>-2.530</td>\n",
       "      <td>-0.815</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>-0.757</td>\n",
       "      <td>0.144</td>\n",
       "      <td>0.553</td>\n",
       "      <td>0.873</td>\n",
       "      <td>-1.651</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.860</td>\n",
       "      <td>-0.657</td>\n",
       "      <td>-0.993</td>\n",
       "      <td>-0.397</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-0.459</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.631</td>\n",
       "      <td>1.751</td>\n",
       "      <td>-2.386</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2096</th>\n",
       "      <td>-0.729</td>\n",
       "      <td>-1.366</td>\n",
       "      <td>-0.532</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.039</td>\n",
       "      <td>0.492</td>\n",
       "      <td>0.763</td>\n",
       "      <td>-0.950</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.889</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-1.176</td>\n",
       "      <td>-0.392</td>\n",
       "      <td>2.082</td>\n",
       "      <td>2.072</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-2.277</td>\n",
       "      <td>0.757</td>\n",
       "      <td>-1.456</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2097</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.588</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>-0.791</td>\n",
       "      <td>0.434</td>\n",
       "      <td>0.109</td>\n",
       "      <td>0.399</td>\n",
       "      <td>0.656</td>\n",
       "      <td>-0.771</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.889</td>\n",
       "      <td>0.060</td>\n",
       "      <td>-0.832</td>\n",
       "      <td>-0.100</td>\n",
       "      <td>2.082</td>\n",
       "      <td>2.072</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.270</td>\n",
       "      <td>0.576</td>\n",
       "      <td>-0.826</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2098</th>\n",
       "      <td>-0.136</td>\n",
       "      <td>-0.493</td>\n",
       "      <td>-0.361</td>\n",
       "      <td>-0.632</td>\n",
       "      <td>0.432</td>\n",
       "      <td>0.124</td>\n",
       "      <td>0.415</td>\n",
       "      <td>0.656</td>\n",
       "      <td>-0.507</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.844</td>\n",
       "      <td>0.124</td>\n",
       "      <td>-0.382</td>\n",
       "      <td>0.917</td>\n",
       "      <td>0.017</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-1.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2099</th>\n",
       "      <td>0.342</td>\n",
       "      <td>0.513</td>\n",
       "      <td>0.078</td>\n",
       "      <td>-0.498</td>\n",
       "      <td>0.796</td>\n",
       "      <td>0.031</td>\n",
       "      <td>0.463</td>\n",
       "      <td>0.610</td>\n",
       "      <td>0.100</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.739</td>\n",
       "      <td>-0.160</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.100</td>\n",
       "      <td>0.132</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.193</td>\n",
       "      <td>-0.015</td>\n",
       "      <td>-0.300</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>2100 rows × 39 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "0     0.566  0.016 -0.143  0.407  0.452 -0.901 -1.812 -2.360 -0.436 -2.114   \n",
       "1     0.968  0.437  0.066  0.566  0.194 -0.893 -1.566 -2.360  0.332 -2.114   \n",
       "2     1.013  0.568  0.235  0.370  0.112 -0.797 -1.367 -2.360  0.396 -2.114   \n",
       "3     0.733  0.368  0.283  0.165  0.599 -0.679 -1.200 -2.086  0.403 -2.114   \n",
       "4     0.684  0.638  0.260  0.209  0.337 -0.454 -1.073 -2.086  0.314 -2.114   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2095 -1.767 -2.530 -0.815 -0.905 -0.757  0.144  0.553  0.873 -1.651  0.042   \n",
       "2096 -0.729 -1.366 -0.532 -0.905 -0.179  0.039  0.492  0.763 -0.950  0.042   \n",
       "2097 -0.394 -0.588 -0.447 -0.791  0.434  0.109  0.399  0.656 -0.771  0.042   \n",
       "2098 -0.136 -0.493 -0.361 -0.632  0.432  0.124  0.415  0.656 -0.507  0.042   \n",
       "2099  0.342  0.513  0.078 -0.498  0.796  0.031  0.463  0.610  0.100  0.042   \n",
       "\n",
       "      ...    V29    V30    V31    V32    V33    V34    V35    V36    V37  \\\n",
       "0     ...  0.136  0.109 -0.615  0.327 -4.627 -4.789 -5.101 -2.608 -3.508   \n",
       "1     ... -0.128  0.124  0.032  0.600 -0.843  0.160  0.364 -0.335 -0.730   \n",
       "2     ... -0.009  0.361  0.277 -0.116 -0.843  0.160  0.364  0.765 -0.589   \n",
       "3     ...  0.015  0.417  0.279  0.603 -0.843 -0.065  0.364  0.333 -0.112   \n",
       "4     ...  0.183  1.078  0.328  0.418 -0.843 -0.215  0.364 -0.280 -0.028   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2095  ...  0.860 -0.657 -0.993 -0.397 -0.212 -0.459  0.364 -0.631  1.751   \n",
       "2096  ...  0.889 -0.212 -1.176 -0.392  2.082  2.072  0.364 -2.277  0.757   \n",
       "2097  ...  0.889  0.060 -0.832 -0.100  2.082  2.072  0.364 -0.270  0.576   \n",
       "2098  ...  0.844  0.124 -0.382  0.917  0.017  0.273  0.364  0.576  0.498   \n",
       "2099  ...  0.739 -0.160 -0.425  0.100  0.132  0.273  0.364 -0.193 -0.015   \n",
       "\n",
       "      target  \n",
       "0      0.175  \n",
       "1      0.676  \n",
       "2      0.633  \n",
       "3      0.206  \n",
       "4      0.384  \n",
       "...      ...  \n",
       "2095  -2.386  \n",
       "2096  -1.456  \n",
       "2097  -0.826  \n",
       "2098  -1.132  \n",
       "2099  -0.300  \n",
       "\n",
       "[2100 rows x 39 columns]"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "train1 = train_data.iloc[:2100,:]\n",
    "train1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "      <th>target</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2100</th>\n",
       "      <td>0.520</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.215</td>\n",
       "      <td>-0.265</td>\n",
       "      <td>0.302</td>\n",
       "      <td>-0.142</td>\n",
       "      <td>0.534</td>\n",
       "      <td>0.610</td>\n",
       "      <td>0.346</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.729</td>\n",
       "      <td>-0.056</td>\n",
       "      <td>0.311</td>\n",
       "      <td>0.072</td>\n",
       "      <td>0.175</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.360</td>\n",
       "      <td>-0.001</td>\n",
       "      <td>-0.319</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2101</th>\n",
       "      <td>0.418</td>\n",
       "      <td>0.302</td>\n",
       "      <td>0.298</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>0.102</td>\n",
       "      <td>-0.635</td>\n",
       "      <td>0.591</td>\n",
       "      <td>0.621</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.399</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.397</td>\n",
       "      <td>-0.293</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.265</td>\n",
       "      <td>-0.663</td>\n",
       "      <td>-0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2102</th>\n",
       "      <td>0.579</td>\n",
       "      <td>0.422</td>\n",
       "      <td>0.367</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.041</td>\n",
       "      <td>0.001</td>\n",
       "      <td>0.705</td>\n",
       "      <td>0.660</td>\n",
       "      <td>0.348</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.139</td>\n",
       "      <td>-0.157</td>\n",
       "      <td>0.408</td>\n",
       "      <td>-0.396</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.197</td>\n",
       "      <td>0.115</td>\n",
       "      <td>0.006</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2103</th>\n",
       "      <td>-0.081</td>\n",
       "      <td>-0.346</td>\n",
       "      <td>0.066</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.166</td>\n",
       "      <td>-0.667</td>\n",
       "      <td>0.661</td>\n",
       "      <td>0.660</td>\n",
       "      <td>-0.544</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.217</td>\n",
       "      <td>-0.285</td>\n",
       "      <td>-0.033</td>\n",
       "      <td>-0.272</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.863</td>\n",
       "      <td>-0.441</td>\n",
       "      <td>-0.449</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2104</th>\n",
       "      <td>-0.626</td>\n",
       "      <td>-0.734</td>\n",
       "      <td>-0.206</td>\n",
       "      <td>-0.218</td>\n",
       "      <td>-0.369</td>\n",
       "      <td>0.150</td>\n",
       "      <td>0.692</td>\n",
       "      <td>0.695</td>\n",
       "      <td>-0.226</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.433</td>\n",
       "      <td>-0.304</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.067</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.481</td>\n",
       "      <td>0.996</td>\n",
       "      <td>-0.738</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2883</th>\n",
       "      <td>0.190</td>\n",
       "      <td>-0.025</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.161</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>0.757</td>\n",
       "      <td>0.584</td>\n",
       "      <td>-0.026</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.128</td>\n",
       "      <td>-0.208</td>\n",
       "      <td>0.809</td>\n",
       "      <td>-0.173</td>\n",
       "      <td>0.247</td>\n",
       "      <td>-0.027</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.686</td>\n",
       "      <td>0.235</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2884</th>\n",
       "      <td>0.507</td>\n",
       "      <td>0.557</td>\n",
       "      <td>0.296</td>\n",
       "      <td>0.183</td>\n",
       "      <td>0.530</td>\n",
       "      <td>-0.237</td>\n",
       "      <td>0.749</td>\n",
       "      <td>0.584</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.287</td>\n",
       "      <td>0.465</td>\n",
       "      <td>-0.310</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>1.042</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2885</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.721</td>\n",
       "      <td>-0.485</td>\n",
       "      <td>0.084</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.034</td>\n",
       "      <td>0.655</td>\n",
       "      <td>0.614</td>\n",
       "      <td>-0.818</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.268</td>\n",
       "      <td>0.552</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.951</td>\n",
       "      <td>0.748</td>\n",
       "      <td>0.005</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2886</th>\n",
       "      <td>-0.219</td>\n",
       "      <td>-0.282</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.449</td>\n",
       "      <td>-0.140</td>\n",
       "      <td>0.560</td>\n",
       "      <td>0.583</td>\n",
       "      <td>-0.596</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.216</td>\n",
       "      <td>1.061</td>\n",
       "      <td>-0.051</td>\n",
       "      <td>1.023</td>\n",
       "      <td>0.878</td>\n",
       "      <td>0.610</td>\n",
       "      <td>-0.230</td>\n",
       "      <td>-0.301</td>\n",
       "      <td>0.555</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2887</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.379</td>\n",
       "      <td>0.092</td>\n",
       "      <td>0.550</td>\n",
       "      <td>0.551</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>0.047</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>0.847</td>\n",
       "      <td>0.534</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>-0.190</td>\n",
       "      <td>-0.567</td>\n",
       "      <td>0.388</td>\n",
       "      <td>0.417</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>788 rows × 39 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "2100  0.520  0.537  0.215 -0.265  0.302 -0.142  0.534  0.610  0.346  0.042   \n",
       "2101  0.418  0.302  0.298 -0.380  0.102 -0.635  0.591  0.621  0.032  0.042   \n",
       "2102  0.579  0.422  0.367 -0.425  0.041  0.001  0.705  0.660  0.348  0.042   \n",
       "2103 -0.081 -0.346  0.066 -0.344 -0.166 -0.667  0.661  0.660 -0.544  0.042   \n",
       "2104 -0.626 -0.734 -0.206 -0.218 -0.369  0.150  0.692  0.695 -0.226  0.042   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  0.190 -0.025 -0.138  0.161  0.600 -0.212  0.757  0.584 -0.026  0.904   \n",
       "2884  0.507  0.557  0.296  0.183  0.530 -0.237  0.749  0.584  0.537  0.904   \n",
       "2885 -0.394 -0.721 -0.485  0.084  0.136  0.034  0.655  0.614 -0.818  0.904   \n",
       "2886 -0.219 -0.282 -0.344 -0.049  0.449 -0.140  0.560  0.583 -0.596  0.904   \n",
       "2887  0.368  0.380 -0.225 -0.049  0.379  0.092  0.550  0.551  0.244  0.904   \n",
       "\n",
       "      ...    V29    V30    V31    V32    V33    V34    V35    V36    V37  \\\n",
       "2100  ...  0.729 -0.056  0.311  0.072  0.175  0.273  0.364  0.360 -0.001   \n",
       "2101  ...  0.399 -0.138  0.397 -0.293  0.190  0.273  0.364  0.265 -0.663   \n",
       "2102  ...  0.139 -0.157  0.408 -0.396  0.190  0.273  0.364  0.197  0.115   \n",
       "2103  ... -0.217 -0.285 -0.033 -0.272  0.190  0.273  0.364  0.863 -0.441   \n",
       "2104  ... -0.433 -0.304  0.008 -0.067  0.190  0.273  0.364  0.481  0.996   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  ...  0.128 -0.208  0.809 -0.173  0.247 -0.027 -0.349  0.576  0.686   \n",
       "2884  ...  0.291 -0.287  0.465 -0.310  0.763  0.498 -0.349 -0.615 -0.380   \n",
       "2885  ...  0.291 -0.179  0.268  0.552  0.763  0.498 -0.349  0.951  0.748   \n",
       "2886  ...  0.216  1.061 -0.051  1.023  0.878  0.610 -0.230 -0.301  0.555   \n",
       "2887  ...  0.047  0.057 -0.042  0.847  0.534 -0.009 -0.190 -0.567  0.388   \n",
       "\n",
       "      target  \n",
       "2100  -0.319  \n",
       "2101  -0.083  \n",
       "2102   0.006  \n",
       "2103  -0.449  \n",
       "2104  -0.738  \n",
       "...      ...  \n",
       "2883   0.235  \n",
       "2884   1.042  \n",
       "2885   0.005  \n",
       "2886   0.350  \n",
       "2887   0.417  \n",
       "\n",
       "[788 rows x 39 columns]"
      ]
     },
     "execution_count": 33,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "test_data = train_data.iloc[2100:,:]\n",
    "test_data"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "      <th>target</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.566</td>\n",
       "      <td>0.016</td>\n",
       "      <td>-0.143</td>\n",
       "      <td>0.407</td>\n",
       "      <td>0.452</td>\n",
       "      <td>-0.901</td>\n",
       "      <td>-1.812</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>-0.436</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>0.327</td>\n",
       "      <td>-4.627</td>\n",
       "      <td>-4.789</td>\n",
       "      <td>-5.101</td>\n",
       "      <td>-2.608</td>\n",
       "      <td>-3.508</td>\n",
       "      <td>0.175</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.968</td>\n",
       "      <td>0.437</td>\n",
       "      <td>0.066</td>\n",
       "      <td>0.566</td>\n",
       "      <td>0.194</td>\n",
       "      <td>-0.893</td>\n",
       "      <td>-1.566</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.332</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.128</td>\n",
       "      <td>0.124</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.335</td>\n",
       "      <td>-0.730</td>\n",
       "      <td>0.676</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1.013</td>\n",
       "      <td>0.568</td>\n",
       "      <td>0.235</td>\n",
       "      <td>0.370</td>\n",
       "      <td>0.112</td>\n",
       "      <td>-0.797</td>\n",
       "      <td>-1.367</td>\n",
       "      <td>-2.360</td>\n",
       "      <td>0.396</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>0.361</td>\n",
       "      <td>0.277</td>\n",
       "      <td>-0.116</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>0.160</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.765</td>\n",
       "      <td>-0.589</td>\n",
       "      <td>0.633</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.733</td>\n",
       "      <td>0.368</td>\n",
       "      <td>0.283</td>\n",
       "      <td>0.165</td>\n",
       "      <td>0.599</td>\n",
       "      <td>-0.679</td>\n",
       "      <td>-1.200</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.403</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.015</td>\n",
       "      <td>0.417</td>\n",
       "      <td>0.279</td>\n",
       "      <td>0.603</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.065</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.333</td>\n",
       "      <td>-0.112</td>\n",
       "      <td>0.206</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.684</td>\n",
       "      <td>0.638</td>\n",
       "      <td>0.260</td>\n",
       "      <td>0.209</td>\n",
       "      <td>0.337</td>\n",
       "      <td>-0.454</td>\n",
       "      <td>-1.073</td>\n",
       "      <td>-2.086</td>\n",
       "      <td>0.314</td>\n",
       "      <td>-2.114</td>\n",
       "      <td>...</td>\n",
       "      <td>0.183</td>\n",
       "      <td>1.078</td>\n",
       "      <td>0.328</td>\n",
       "      <td>0.418</td>\n",
       "      <td>-0.843</td>\n",
       "      <td>-0.215</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.280</td>\n",
       "      <td>-0.028</td>\n",
       "      <td>0.384</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2095</th>\n",
       "      <td>-1.767</td>\n",
       "      <td>-2.530</td>\n",
       "      <td>-0.815</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>-0.757</td>\n",
       "      <td>0.144</td>\n",
       "      <td>0.553</td>\n",
       "      <td>0.873</td>\n",
       "      <td>-1.651</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.860</td>\n",
       "      <td>-0.657</td>\n",
       "      <td>-0.993</td>\n",
       "      <td>-0.397</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-0.459</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.631</td>\n",
       "      <td>1.751</td>\n",
       "      <td>-2.386</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2096</th>\n",
       "      <td>-0.729</td>\n",
       "      <td>-1.366</td>\n",
       "      <td>-0.532</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.039</td>\n",
       "      <td>0.492</td>\n",
       "      <td>0.763</td>\n",
       "      <td>-0.950</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.889</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-1.176</td>\n",
       "      <td>-0.392</td>\n",
       "      <td>2.082</td>\n",
       "      <td>2.072</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-2.277</td>\n",
       "      <td>0.757</td>\n",
       "      <td>-1.456</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2097</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.588</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>-0.791</td>\n",
       "      <td>0.434</td>\n",
       "      <td>0.109</td>\n",
       "      <td>0.399</td>\n",
       "      <td>0.656</td>\n",
       "      <td>-0.771</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.889</td>\n",
       "      <td>0.060</td>\n",
       "      <td>-0.832</td>\n",
       "      <td>-0.100</td>\n",
       "      <td>2.082</td>\n",
       "      <td>2.072</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.270</td>\n",
       "      <td>0.576</td>\n",
       "      <td>-0.826</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2098</th>\n",
       "      <td>-0.136</td>\n",
       "      <td>-0.493</td>\n",
       "      <td>-0.361</td>\n",
       "      <td>-0.632</td>\n",
       "      <td>0.432</td>\n",
       "      <td>0.124</td>\n",
       "      <td>0.415</td>\n",
       "      <td>0.656</td>\n",
       "      <td>-0.507</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.844</td>\n",
       "      <td>0.124</td>\n",
       "      <td>-0.382</td>\n",
       "      <td>0.917</td>\n",
       "      <td>0.017</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-1.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2099</th>\n",
       "      <td>0.342</td>\n",
       "      <td>0.513</td>\n",
       "      <td>0.078</td>\n",
       "      <td>-0.498</td>\n",
       "      <td>0.796</td>\n",
       "      <td>0.031</td>\n",
       "      <td>0.463</td>\n",
       "      <td>0.610</td>\n",
       "      <td>0.100</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>0.739</td>\n",
       "      <td>-0.160</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.100</td>\n",
       "      <td>0.132</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>-0.193</td>\n",
       "      <td>-0.015</td>\n",
       "      <td>-0.300</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>2098 rows × 39 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "0     0.566  0.016 -0.143  0.407  0.452 -0.901 -1.812 -2.360 -0.436 -2.114   \n",
       "1     0.968  0.437  0.066  0.566  0.194 -0.893 -1.566 -2.360  0.332 -2.114   \n",
       "2     1.013  0.568  0.235  0.370  0.112 -0.797 -1.367 -2.360  0.396 -2.114   \n",
       "3     0.733  0.368  0.283  0.165  0.599 -0.679 -1.200 -2.086  0.403 -2.114   \n",
       "4     0.684  0.638  0.260  0.209  0.337 -0.454 -1.073 -2.086  0.314 -2.114   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2095 -1.767 -2.530 -0.815 -0.905 -0.757  0.144  0.553  0.873 -1.651  0.042   \n",
       "2096 -0.729 -1.366 -0.532 -0.905 -0.179  0.039  0.492  0.763 -0.950  0.042   \n",
       "2097 -0.394 -0.588 -0.447 -0.791  0.434  0.109  0.399  0.656 -0.771  0.042   \n",
       "2098 -0.136 -0.493 -0.361 -0.632  0.432  0.124  0.415  0.656 -0.507  0.042   \n",
       "2099  0.342  0.513  0.078 -0.498  0.796  0.031  0.463  0.610  0.100  0.042   \n",
       "\n",
       "      ...    V29    V30    V31    V32    V33    V34    V35    V36    V37  \\\n",
       "0     ...  0.136  0.109 -0.615  0.327 -4.627 -4.789 -5.101 -2.608 -3.508   \n",
       "1     ... -0.128  0.124  0.032  0.600 -0.843  0.160  0.364 -0.335 -0.730   \n",
       "2     ... -0.009  0.361  0.277 -0.116 -0.843  0.160  0.364  0.765 -0.589   \n",
       "3     ...  0.015  0.417  0.279  0.603 -0.843 -0.065  0.364  0.333 -0.112   \n",
       "4     ...  0.183  1.078  0.328  0.418 -0.843 -0.215  0.364 -0.280 -0.028   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2095  ...  0.860 -0.657 -0.993 -0.397 -0.212 -0.459  0.364 -0.631  1.751   \n",
       "2096  ...  0.889 -0.212 -1.176 -0.392  2.082  2.072  0.364 -2.277  0.757   \n",
       "2097  ...  0.889  0.060 -0.832 -0.100  2.082  2.072  0.364 -0.270  0.576   \n",
       "2098  ...  0.844  0.124 -0.382  0.917  0.017  0.273  0.364  0.576  0.498   \n",
       "2099  ...  0.739 -0.160 -0.425  0.100  0.132  0.273  0.364 -0.193 -0.015   \n",
       "\n",
       "      target  \n",
       "0      0.175  \n",
       "1      0.676  \n",
       "2      0.633  \n",
       "3      0.206  \n",
       "4      0.384  \n",
       "...      ...  \n",
       "2095  -2.386  \n",
       "2096  -1.456  \n",
       "2097  -0.826  \n",
       "2098  -1.132  \n",
       "2099  -0.300  \n",
       "\n",
       "[2098 rows x 39 columns]"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "train2 = train1[train1['V9']>-7.5]\n",
    "new_numerical=['V0', 'V1', 'V8', 'V27', 'V31', 'V2', 'V3','V37','V20', 'V10',\n",
    "               'V5', 'V24', 'V13', 'V19', 'V18','V30','V22','target']\n",
    "train2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V8</th>\n",
       "      <th>V27</th>\n",
       "      <th>V31</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V37</th>\n",
       "      <th>V20</th>\n",
       "      <th>V10</th>\n",
       "      <th>V5</th>\n",
       "      <th>V24</th>\n",
       "      <th>V13</th>\n",
       "      <th>V19</th>\n",
       "      <th>V18</th>\n",
       "      <th>V30</th>\n",
       "      <th>V22</th>\n",
       "      <th>target</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.566</td>\n",
       "      <td>0.016</td>\n",
       "      <td>-0.436</td>\n",
       "      <td>0.168</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>-0.143</td>\n",
       "      <td>0.407</td>\n",
       "      <td>-3.508</td>\n",
       "      <td>0.610</td>\n",
       "      <td>-0.940</td>\n",
       "      <td>-0.901</td>\n",
       "      <td>0.800</td>\n",
       "      <td>0.550</td>\n",
       "      <td>-0.991</td>\n",
       "      <td>-0.573</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-0.063</td>\n",
       "      <td>0.175</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.968</td>\n",
       "      <td>0.437</td>\n",
       "      <td>0.332</td>\n",
       "      <td>0.338</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.066</td>\n",
       "      <td>0.566</td>\n",
       "      <td>-0.730</td>\n",
       "      <td>0.588</td>\n",
       "      <td>0.188</td>\n",
       "      <td>-0.893</td>\n",
       "      <td>0.801</td>\n",
       "      <td>1.109</td>\n",
       "      <td>-0.836</td>\n",
       "      <td>-0.571</td>\n",
       "      <td>0.124</td>\n",
       "      <td>-0.063</td>\n",
       "      <td>0.676</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1.013</td>\n",
       "      <td>0.568</td>\n",
       "      <td>0.396</td>\n",
       "      <td>0.326</td>\n",
       "      <td>0.277</td>\n",
       "      <td>0.235</td>\n",
       "      <td>0.370</td>\n",
       "      <td>-0.589</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.874</td>\n",
       "      <td>-0.797</td>\n",
       "      <td>0.961</td>\n",
       "      <td>0.767</td>\n",
       "      <td>-0.558</td>\n",
       "      <td>-0.564</td>\n",
       "      <td>0.361</td>\n",
       "      <td>-0.063</td>\n",
       "      <td>0.633</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.733</td>\n",
       "      <td>0.368</td>\n",
       "      <td>0.403</td>\n",
       "      <td>0.277</td>\n",
       "      <td>0.279</td>\n",
       "      <td>0.283</td>\n",
       "      <td>0.165</td>\n",
       "      <td>-0.112</td>\n",
       "      <td>0.272</td>\n",
       "      <td>0.011</td>\n",
       "      <td>-0.679</td>\n",
       "      <td>1.435</td>\n",
       "      <td>0.769</td>\n",
       "      <td>-0.564</td>\n",
       "      <td>-0.574</td>\n",
       "      <td>0.417</td>\n",
       "      <td>-0.063</td>\n",
       "      <td>0.206</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.684</td>\n",
       "      <td>0.638</td>\n",
       "      <td>0.314</td>\n",
       "      <td>0.332</td>\n",
       "      <td>0.328</td>\n",
       "      <td>0.260</td>\n",
       "      <td>0.209</td>\n",
       "      <td>-0.028</td>\n",
       "      <td>0.106</td>\n",
       "      <td>-0.251</td>\n",
       "      <td>-0.454</td>\n",
       "      <td>0.881</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.572</td>\n",
       "      <td>1.078</td>\n",
       "      <td>-0.259</td>\n",
       "      <td>0.384</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2095</th>\n",
       "      <td>-1.767</td>\n",
       "      <td>-2.530</td>\n",
       "      <td>-1.651</td>\n",
       "      <td>-0.343</td>\n",
       "      <td>-0.993</td>\n",
       "      <td>-0.815</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>1.751</td>\n",
       "      <td>-1.282</td>\n",
       "      <td>-0.460</td>\n",
       "      <td>0.144</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-0.659</td>\n",
       "      <td>0.206</td>\n",
       "      <td>3.445</td>\n",
       "      <td>-0.657</td>\n",
       "      <td>-0.621</td>\n",
       "      <td>-2.386</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2096</th>\n",
       "      <td>-0.729</td>\n",
       "      <td>-1.366</td>\n",
       "      <td>-0.950</td>\n",
       "      <td>-0.078</td>\n",
       "      <td>-1.176</td>\n",
       "      <td>-0.532</td>\n",
       "      <td>-0.905</td>\n",
       "      <td>0.757</td>\n",
       "      <td>-0.651</td>\n",
       "      <td>-1.828</td>\n",
       "      <td>0.039</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-1.695</td>\n",
       "      <td>0.169</td>\n",
       "      <td>0.079</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-0.817</td>\n",
       "      <td>-1.456</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2097</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.588</td>\n",
       "      <td>-0.771</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.832</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>-0.791</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.117</td>\n",
       "      <td>-0.371</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-0.584</td>\n",
       "      <td>0.378</td>\n",
       "      <td>0.066</td>\n",
       "      <td>0.060</td>\n",
       "      <td>-0.735</td>\n",
       "      <td>-0.826</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2098</th>\n",
       "      <td>-0.136</td>\n",
       "      <td>-0.493</td>\n",
       "      <td>-0.507</td>\n",
       "      <td>0.055</td>\n",
       "      <td>-0.382</td>\n",
       "      <td>-0.361</td>\n",
       "      <td>-0.632</td>\n",
       "      <td>0.498</td>\n",
       "      <td>0.530</td>\n",
       "      <td>0.404</td>\n",
       "      <td>0.124</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-0.642</td>\n",
       "      <td>-0.044</td>\n",
       "      <td>0.216</td>\n",
       "      <td>0.124</td>\n",
       "      <td>-0.621</td>\n",
       "      <td>-1.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2099</th>\n",
       "      <td>0.342</td>\n",
       "      <td>0.513</td>\n",
       "      <td>0.100</td>\n",
       "      <td>0.263</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.078</td>\n",
       "      <td>-0.498</td>\n",
       "      <td>-0.015</td>\n",
       "      <td>1.312</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>0.031</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-0.761</td>\n",
       "      <td>0.301</td>\n",
       "      <td>0.258</td>\n",
       "      <td>-0.160</td>\n",
       "      <td>-0.621</td>\n",
       "      <td>-0.300</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>2098 rows × 18 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V8    V27    V31     V2     V3    V37    V20    V10  \\\n",
       "0     0.566  0.016 -0.436  0.168 -0.615 -0.143  0.407 -3.508  0.610 -0.940   \n",
       "1     0.968  0.437  0.332  0.338  0.032  0.066  0.566 -0.730  0.588  0.188   \n",
       "2     1.013  0.568  0.396  0.326  0.277  0.235  0.370 -0.589  0.576  0.874   \n",
       "3     0.733  0.368  0.403  0.277  0.279  0.283  0.165 -0.112  0.272  0.011   \n",
       "4     0.684  0.638  0.314  0.332  0.328  0.260  0.209 -0.028  0.106 -0.251   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2095 -1.767 -2.530 -1.651 -0.343 -0.993 -0.815 -0.905  1.751 -1.282 -0.460   \n",
       "2096 -0.729 -1.366 -0.950 -0.078 -1.176 -0.532 -0.905  0.757 -0.651 -1.828   \n",
       "2097 -0.394 -0.588 -0.771  0.057 -0.832 -0.447 -0.791  0.576  0.117 -0.371   \n",
       "2098 -0.136 -0.493 -0.507  0.055 -0.382 -0.361 -0.632  0.498  0.530  0.404   \n",
       "2099  0.342  0.513  0.100  0.263 -0.425  0.078 -0.498 -0.015  1.312 -0.225   \n",
       "\n",
       "         V5    V24    V13    V19    V18    V30    V22  target  \n",
       "0    -0.901  0.800  0.550 -0.991 -0.573  0.109 -0.063   0.175  \n",
       "1    -0.893  0.801  1.109 -0.836 -0.571  0.124 -0.063   0.676  \n",
       "2    -0.797  0.961  0.767 -0.558 -0.564  0.361 -0.063   0.633  \n",
       "3    -0.679  1.435  0.769 -0.564 -0.574  0.417 -0.063   0.206  \n",
       "4    -0.454  0.881 -0.349 -0.394 -0.572  1.078 -0.259   0.384  \n",
       "...     ...    ...    ...    ...    ...    ...    ...     ...  \n",
       "2095  0.144 -1.191 -0.659  0.206  3.445 -0.657 -0.621  -2.386  \n",
       "2096  0.039 -1.191 -1.695  0.169  0.079 -0.212 -0.817  -1.456  \n",
       "2097  0.109 -1.191 -0.584  0.378  0.066  0.060 -0.735  -0.826  \n",
       "2098  0.124 -1.191 -0.642 -0.044  0.216  0.124 -0.621  -1.132  \n",
       "2099  0.031 -1.191 -0.761  0.301  0.258 -0.160 -0.621  -0.300  \n",
       "\n",
       "[2098 rows x 18 columns]"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "train3 = train2[new_numerical]\n",
    "train3"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [],
   "source": [
    "features = train3.iloc[:,:-1]\n",
    "targets = train3.iloc[:,-1]\n",
    "xtrain,xval,ytrain,yval = train_test_split(features,targets,test_size=0.3)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [],
   "source": [
    "from sklearn.metrics import mean_squared_error\n",
    "# MSE\n",
    "#mse_predict = mean_squared_error(y_test, y_predict)\n",
    "# MAE\n",
    "#mae_predict = mean_absolute_error(y_test, y_predict)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V28</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2100</th>\n",
       "      <td>0.520</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.215</td>\n",
       "      <td>-0.265</td>\n",
       "      <td>0.302</td>\n",
       "      <td>-0.142</td>\n",
       "      <td>0.534</td>\n",
       "      <td>0.610</td>\n",
       "      <td>0.346</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.450</td>\n",
       "      <td>0.729</td>\n",
       "      <td>-0.056</td>\n",
       "      <td>0.311</td>\n",
       "      <td>0.072</td>\n",
       "      <td>0.175</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.360</td>\n",
       "      <td>-0.001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2101</th>\n",
       "      <td>0.418</td>\n",
       "      <td>0.302</td>\n",
       "      <td>0.298</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>0.102</td>\n",
       "      <td>-0.635</td>\n",
       "      <td>0.591</td>\n",
       "      <td>0.621</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>0.399</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.397</td>\n",
       "      <td>-0.293</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.265</td>\n",
       "      <td>-0.663</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2102</th>\n",
       "      <td>0.579</td>\n",
       "      <td>0.422</td>\n",
       "      <td>0.367</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.041</td>\n",
       "      <td>0.001</td>\n",
       "      <td>0.705</td>\n",
       "      <td>0.660</td>\n",
       "      <td>0.348</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.444</td>\n",
       "      <td>0.139</td>\n",
       "      <td>-0.157</td>\n",
       "      <td>0.408</td>\n",
       "      <td>-0.396</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.197</td>\n",
       "      <td>0.115</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2103</th>\n",
       "      <td>-0.081</td>\n",
       "      <td>-0.346</td>\n",
       "      <td>0.066</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.166</td>\n",
       "      <td>-0.667</td>\n",
       "      <td>0.661</td>\n",
       "      <td>0.660</td>\n",
       "      <td>-0.544</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>1.296</td>\n",
       "      <td>-0.217</td>\n",
       "      <td>-0.285</td>\n",
       "      <td>-0.033</td>\n",
       "      <td>-0.272</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.863</td>\n",
       "      <td>-0.441</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2104</th>\n",
       "      <td>-0.626</td>\n",
       "      <td>-0.734</td>\n",
       "      <td>-0.206</td>\n",
       "      <td>-0.218</td>\n",
       "      <td>-0.369</td>\n",
       "      <td>0.150</td>\n",
       "      <td>0.692</td>\n",
       "      <td>0.695</td>\n",
       "      <td>-0.226</td>\n",
       "      <td>0.042</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.450</td>\n",
       "      <td>-0.433</td>\n",
       "      <td>-0.304</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.067</td>\n",
       "      <td>0.190</td>\n",
       "      <td>0.273</td>\n",
       "      <td>0.364</td>\n",
       "      <td>0.481</td>\n",
       "      <td>0.996</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2883</th>\n",
       "      <td>0.190</td>\n",
       "      <td>-0.025</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.161</td>\n",
       "      <td>0.600</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>0.757</td>\n",
       "      <td>0.584</td>\n",
       "      <td>-0.026</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.449</td>\n",
       "      <td>0.128</td>\n",
       "      <td>-0.208</td>\n",
       "      <td>0.809</td>\n",
       "      <td>-0.173</td>\n",
       "      <td>0.247</td>\n",
       "      <td>-0.027</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.576</td>\n",
       "      <td>0.686</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2884</th>\n",
       "      <td>0.507</td>\n",
       "      <td>0.557</td>\n",
       "      <td>0.296</td>\n",
       "      <td>0.183</td>\n",
       "      <td>0.530</td>\n",
       "      <td>-0.237</td>\n",
       "      <td>0.749</td>\n",
       "      <td>0.584</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.439</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.287</td>\n",
       "      <td>0.465</td>\n",
       "      <td>-0.310</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>-0.615</td>\n",
       "      <td>-0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2885</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.721</td>\n",
       "      <td>-0.485</td>\n",
       "      <td>0.084</td>\n",
       "      <td>0.136</td>\n",
       "      <td>0.034</td>\n",
       "      <td>0.655</td>\n",
       "      <td>0.614</td>\n",
       "      <td>-0.818</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.445</td>\n",
       "      <td>0.291</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.268</td>\n",
       "      <td>0.552</td>\n",
       "      <td>0.763</td>\n",
       "      <td>0.498</td>\n",
       "      <td>-0.349</td>\n",
       "      <td>0.951</td>\n",
       "      <td>0.748</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2886</th>\n",
       "      <td>-0.219</td>\n",
       "      <td>-0.282</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.449</td>\n",
       "      <td>-0.140</td>\n",
       "      <td>0.560</td>\n",
       "      <td>0.583</td>\n",
       "      <td>-0.596</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.448</td>\n",
       "      <td>0.216</td>\n",
       "      <td>1.061</td>\n",
       "      <td>-0.051</td>\n",
       "      <td>1.023</td>\n",
       "      <td>0.878</td>\n",
       "      <td>0.610</td>\n",
       "      <td>-0.230</td>\n",
       "      <td>-0.301</td>\n",
       "      <td>0.555</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2887</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.379</td>\n",
       "      <td>0.092</td>\n",
       "      <td>0.550</td>\n",
       "      <td>0.551</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.449</td>\n",
       "      <td>0.047</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>0.847</td>\n",
       "      <td>0.534</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>-0.190</td>\n",
       "      <td>-0.567</td>\n",
       "      <td>0.388</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>788 rows × 38 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "2100  0.520  0.537  0.215 -0.265  0.302 -0.142  0.534  0.610  0.346  0.042   \n",
       "2101  0.418  0.302  0.298 -0.380  0.102 -0.635  0.591  0.621  0.032  0.042   \n",
       "2102  0.579  0.422  0.367 -0.425  0.041  0.001  0.705  0.660  0.348  0.042   \n",
       "2103 -0.081 -0.346  0.066 -0.344 -0.166 -0.667  0.661  0.660 -0.544  0.042   \n",
       "2104 -0.626 -0.734 -0.206 -0.218 -0.369  0.150  0.692  0.695 -0.226  0.042   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  0.190 -0.025 -0.138  0.161  0.600 -0.212  0.757  0.584 -0.026  0.904   \n",
       "2884  0.507  0.557  0.296  0.183  0.530 -0.237  0.749  0.584  0.537  0.904   \n",
       "2885 -0.394 -0.721 -0.485  0.084  0.136  0.034  0.655  0.614 -0.818  0.904   \n",
       "2886 -0.219 -0.282 -0.344 -0.049  0.449 -0.140  0.560  0.583 -0.596  0.904   \n",
       "2887  0.368  0.380 -0.225 -0.049  0.379  0.092  0.550  0.551  0.244  0.904   \n",
       "\n",
       "      ...    V28    V29    V30    V31    V32    V33    V34    V35    V36  \\\n",
       "2100  ... -0.450  0.729 -0.056  0.311  0.072  0.175  0.273  0.364  0.360   \n",
       "2101  ... -0.447  0.399 -0.138  0.397 -0.293  0.190  0.273  0.364  0.265   \n",
       "2102  ... -0.444  0.139 -0.157  0.408 -0.396  0.190  0.273  0.364  0.197   \n",
       "2103  ...  1.296 -0.217 -0.285 -0.033 -0.272  0.190  0.273  0.364  0.863   \n",
       "2104  ... -0.450 -0.433 -0.304  0.008 -0.067  0.190  0.273  0.364  0.481   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  ... -0.449  0.128 -0.208  0.809 -0.173  0.247 -0.027 -0.349  0.576   \n",
       "2884  ... -0.439  0.291 -0.287  0.465 -0.310  0.763  0.498 -0.349 -0.615   \n",
       "2885  ... -0.445  0.291 -0.179  0.268  0.552  0.763  0.498 -0.349  0.951   \n",
       "2886  ... -0.448  0.216  1.061 -0.051  1.023  0.878  0.610 -0.230 -0.301   \n",
       "2887  ... -0.449  0.047  0.057 -0.042  0.847  0.534 -0.009 -0.190 -0.567   \n",
       "\n",
       "        V37  \n",
       "2100 -0.001  \n",
       "2101 -0.663  \n",
       "2102  0.115  \n",
       "2103 -0.441  \n",
       "2104  0.996  \n",
       "...     ...  \n",
       "2883  0.686  \n",
       "2884 -0.380  \n",
       "2885  0.748  \n",
       "2886  0.555  \n",
       "2887  0.388  \n",
       "\n",
       "[788 rows x 38 columns]"
      ]
     },
     "execution_count": 35,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "test_features = test_data.iloc[:,:-1]\n",
    "test_targets = test_data.iloc[:,-1]\n",
    "test_features"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2100   -0.319\n",
       "2101   -0.083\n",
       "2102    0.006\n",
       "2103   -0.449\n",
       "2104   -0.738\n",
       "        ...  \n",
       "2883    0.235\n",
       "2884    1.042\n",
       "2885    0.005\n",
       "2886    0.350\n",
       "2887    0.417\n",
       "Name: target, Length: 788, dtype: float64"
      ]
     },
     "execution_count": 36,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "test_target"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {},
   "outputs": [],
   "source": [
    "test_numi = ['V0',\n",
    " 'V1',\n",
    " 'V8',\n",
    " 'V27',\n",
    " 'V31',\n",
    " 'V2',\n",
    " 'V3',\n",
    " 'V37',\n",
    " 'V20',\n",
    " 'V10',\n",
    " 'V5',\n",
    " 'V24',\n",
    " 'V13',\n",
    " 'V19',\n",
    " 'V18',\n",
    " 'V30',\n",
    " 'V22']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V8</th>\n",
       "      <th>V27</th>\n",
       "      <th>V31</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V37</th>\n",
       "      <th>V20</th>\n",
       "      <th>V10</th>\n",
       "      <th>V5</th>\n",
       "      <th>V24</th>\n",
       "      <th>V13</th>\n",
       "      <th>V19</th>\n",
       "      <th>V18</th>\n",
       "      <th>V30</th>\n",
       "      <th>V22</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2100</th>\n",
       "      <td>0.520</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.346</td>\n",
       "      <td>0.281</td>\n",
       "      <td>0.311</td>\n",
       "      <td>0.215</td>\n",
       "      <td>-0.265</td>\n",
       "      <td>-0.001</td>\n",
       "      <td>2.420</td>\n",
       "      <td>0.305</td>\n",
       "      <td>-0.142</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-1.261</td>\n",
       "      <td>0.265</td>\n",
       "      <td>0.251</td>\n",
       "      <td>-0.056</td>\n",
       "      <td>-0.621</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2101</th>\n",
       "      <td>0.418</td>\n",
       "      <td>0.302</td>\n",
       "      <td>0.032</td>\n",
       "      <td>0.293</td>\n",
       "      <td>0.397</td>\n",
       "      <td>0.298</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>-0.663</td>\n",
       "      <td>2.551</td>\n",
       "      <td>0.172</td>\n",
       "      <td>-0.635</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-0.976</td>\n",
       "      <td>0.266</td>\n",
       "      <td>0.248</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>-0.621</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2102</th>\n",
       "      <td>0.579</td>\n",
       "      <td>0.422</td>\n",
       "      <td>0.348</td>\n",
       "      <td>0.267</td>\n",
       "      <td>0.408</td>\n",
       "      <td>0.367</td>\n",
       "      <td>-0.425</td>\n",
       "      <td>0.115</td>\n",
       "      <td>3.262</td>\n",
       "      <td>0.544</td>\n",
       "      <td>0.001</td>\n",
       "      <td>-1.191</td>\n",
       "      <td>-1.668</td>\n",
       "      <td>0.928</td>\n",
       "      <td>0.254</td>\n",
       "      <td>-0.157</td>\n",
       "      <td>-0.621</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2103</th>\n",
       "      <td>-0.081</td>\n",
       "      <td>-0.346</td>\n",
       "      <td>-0.544</td>\n",
       "      <td>0.131</td>\n",
       "      <td>-0.033</td>\n",
       "      <td>0.066</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.441</td>\n",
       "      <td>3.082</td>\n",
       "      <td>0.212</td>\n",
       "      <td>-0.667</td>\n",
       "      <td>-1.190</td>\n",
       "      <td>-0.402</td>\n",
       "      <td>0.743</td>\n",
       "      <td>0.258</td>\n",
       "      <td>-0.285</td>\n",
       "      <td>-0.621</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2104</th>\n",
       "      <td>-0.626</td>\n",
       "      <td>-0.734</td>\n",
       "      <td>-0.226</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.206</td>\n",
       "      <td>-0.218</td>\n",
       "      <td>0.996</td>\n",
       "      <td>2.755</td>\n",
       "      <td>0.565</td>\n",
       "      <td>0.150</td>\n",
       "      <td>-0.052</td>\n",
       "      <td>-1.116</td>\n",
       "      <td>0.638</td>\n",
       "      <td>0.265</td>\n",
       "      <td>-0.304</td>\n",
       "      <td>-0.817</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2883</th>\n",
       "      <td>0.190</td>\n",
       "      <td>-0.025</td>\n",
       "      <td>-0.026</td>\n",
       "      <td>0.189</td>\n",
       "      <td>0.809</td>\n",
       "      <td>-0.138</td>\n",
       "      <td>0.161</td>\n",
       "      <td>0.686</td>\n",
       "      <td>0.598</td>\n",
       "      <td>0.355</td>\n",
       "      <td>-0.212</td>\n",
       "      <td>-1.310</td>\n",
       "      <td>0.141</td>\n",
       "      <td>1.003</td>\n",
       "      <td>0.454</td>\n",
       "      <td>-0.208</td>\n",
       "      <td>0.314</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2884</th>\n",
       "      <td>0.507</td>\n",
       "      <td>0.557</td>\n",
       "      <td>0.537</td>\n",
       "      <td>0.372</td>\n",
       "      <td>0.465</td>\n",
       "      <td>0.296</td>\n",
       "      <td>0.183</td>\n",
       "      <td>-0.380</td>\n",
       "      <td>0.562</td>\n",
       "      <td>-0.061</td>\n",
       "      <td>-0.237</td>\n",
       "      <td>-1.314</td>\n",
       "      <td>-0.634</td>\n",
       "      <td>1.076</td>\n",
       "      <td>0.808</td>\n",
       "      <td>-0.287</td>\n",
       "      <td>0.314</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2885</th>\n",
       "      <td>-0.394</td>\n",
       "      <td>-0.721</td>\n",
       "      <td>-0.818</td>\n",
       "      <td>0.058</td>\n",
       "      <td>0.268</td>\n",
       "      <td>-0.485</td>\n",
       "      <td>0.084</td>\n",
       "      <td>0.748</td>\n",
       "      <td>-0.188</td>\n",
       "      <td>0.240</td>\n",
       "      <td>0.034</td>\n",
       "      <td>-1.310</td>\n",
       "      <td>0.389</td>\n",
       "      <td>1.042</td>\n",
       "      <td>0.813</td>\n",
       "      <td>-0.179</td>\n",
       "      <td>0.133</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2886</th>\n",
       "      <td>-0.219</td>\n",
       "      <td>-0.282</td>\n",
       "      <td>-0.596</td>\n",
       "      <td>0.133</td>\n",
       "      <td>-0.051</td>\n",
       "      <td>-0.344</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.555</td>\n",
       "      <td>-0.497</td>\n",
       "      <td>-0.395</td>\n",
       "      <td>-0.140</td>\n",
       "      <td>-1.313</td>\n",
       "      <td>-0.310</td>\n",
       "      <td>1.129</td>\n",
       "      <td>0.803</td>\n",
       "      <td>1.061</td>\n",
       "      <td>0.019</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2887</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.208</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.388</td>\n",
       "      <td>-0.252</td>\n",
       "      <td>-0.419</td>\n",
       "      <td>0.092</td>\n",
       "      <td>-1.314</td>\n",
       "      <td>-0.114</td>\n",
       "      <td>0.899</td>\n",
       "      <td>0.247</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.063</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>788 rows × 17 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V8    V27    V31     V2     V3    V37    V20    V10  \\\n",
       "2100  0.520  0.537  0.346  0.281  0.311  0.215 -0.265 -0.001  2.420  0.305   \n",
       "2101  0.418  0.302  0.032  0.293  0.397  0.298 -0.380 -0.663  2.551  0.172   \n",
       "2102  0.579  0.422  0.348  0.267  0.408  0.367 -0.425  0.115  3.262  0.544   \n",
       "2103 -0.081 -0.346 -0.544  0.131 -0.033  0.066 -0.344 -0.441  3.082  0.212   \n",
       "2104 -0.626 -0.734 -0.226 -0.049  0.008 -0.206 -0.218  0.996  2.755  0.565   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "2883  0.190 -0.025 -0.026  0.189  0.809 -0.138  0.161  0.686  0.598  0.355   \n",
       "2884  0.507  0.557  0.537  0.372  0.465  0.296  0.183 -0.380  0.562 -0.061   \n",
       "2885 -0.394 -0.721 -0.818  0.058  0.268 -0.485  0.084  0.748 -0.188  0.240   \n",
       "2886 -0.219 -0.282 -0.596  0.133 -0.051 -0.344 -0.049  0.555 -0.497 -0.395   \n",
       "2887  0.368  0.380  0.244  0.208 -0.042 -0.225 -0.049  0.388 -0.252 -0.419   \n",
       "\n",
       "         V5    V24    V13    V19    V18    V30    V22  \n",
       "2100 -0.142 -1.191 -1.261  0.265  0.251 -0.056 -0.621  \n",
       "2101 -0.635 -1.191 -0.976  0.266  0.248 -0.138 -0.621  \n",
       "2102  0.001 -1.191 -1.668  0.928  0.254 -0.157 -0.621  \n",
       "2103 -0.667 -1.190 -0.402  0.743  0.258 -0.285 -0.621  \n",
       "2104  0.150 -0.052 -1.116  0.638  0.265 -0.304 -0.817  \n",
       "...     ...    ...    ...    ...    ...    ...    ...  \n",
       "2883 -0.212 -1.310  0.141  1.003  0.454 -0.208  0.314  \n",
       "2884 -0.237 -1.314 -0.634  1.076  0.808 -0.287  0.314  \n",
       "2885  0.034 -1.310  0.389  1.042  0.813 -0.179  0.133  \n",
       "2886 -0.140 -1.313 -0.310  1.129  0.803  1.061  0.019  \n",
       "2887  0.092 -1.314 -0.114  0.899  0.247  0.057 -0.063  \n",
       "\n",
       "[788 rows x 17 columns]"
      ]
     },
     "execution_count": 41,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "test_paras = test_features[test_numi]\n",
    "test_paras"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 43,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.21816270317460315\n",
      "MSE_Test: 0.3585117220812183\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(1.0, 0.7821517120971624, 0.5965536613927573)"
      ]
     },
     "execution_count": 43,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#回归树\n",
    "m0 = DecisionTreeRegressor()\n",
    "m0.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m0.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m0.predict(test_paras)))\n",
    "m0.score(xtrain,ytrain),m0.score(xval,yval),m0.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 44,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.11954427894730156\n",
      "MSE_Test: 0.18775951936941623\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(0.9832333141493611, 0.8806280078203552, 0.7887073533091176)"
      ]
     },
     "execution_count": 44,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#随机森林\n",
    "m1 = RandomForestRegressor()\n",
    "m1.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m1.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m1.predict(test_paras)))\n",
    "m1.score(xtrain,ytrain),m1.score(xval,yval),m1.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 80,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.11881421515864321\n",
      "MSE_Test: 0.18992496690936975\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(0.9419446362800638, 0.8813570194438122, 0.7862704960806604)"
      ]
     },
     "execution_count": 80,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#GBDT\n",
    "m3 = GradientBoostingRegressor()\n",
    "m3.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m3.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m3.predict(test_paras)))\n",
    "m3.score(xtrain,ytrain),m3.score(xval,yval),m3.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.14058273255804277\n",
      "MSE_Test: 0.2088463050406771\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(0.9994662062205477, 0.8596198747502624, 0.7649776230155609)"
      ]
     },
     "execution_count": 47,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#XGboost\n",
    "m4 = XGBRegressor()\n",
    "m4.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m4.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m4.predict(test_paras)))\n",
    "m4.score(xtrain,ytrain),m4.score(xval,yval),m4.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 49,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.1294282422754322\n",
      "MSE_Test: 0.19158699009307661\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(0.9315344485041316, 0.8707582892232015, 0.7844001606722271)"
      ]
     },
     "execution_count": 49,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#XGBRF\n",
    "m5 = XGBRFRegressor()\n",
    "m5.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m5.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m5.predict(test_paras)))\n",
    "m5.score(xtrain,ytrain),m5.score(xval,yval),m5.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 50,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V4</th>\n",
       "      <th>V5</th>\n",
       "      <th>V6</th>\n",
       "      <th>V7</th>\n",
       "      <th>V8</th>\n",
       "      <th>V9</th>\n",
       "      <th>...</th>\n",
       "      <th>V28</th>\n",
       "      <th>V29</th>\n",
       "      <th>V30</th>\n",
       "      <th>V31</th>\n",
       "      <th>V32</th>\n",
       "      <th>V33</th>\n",
       "      <th>V34</th>\n",
       "      <th>V35</th>\n",
       "      <th>V36</th>\n",
       "      <th>V37</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.379</td>\n",
       "      <td>0.092</td>\n",
       "      <td>0.550</td>\n",
       "      <td>0.551</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.449</td>\n",
       "      <td>0.047</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>0.847</td>\n",
       "      <td>0.534</td>\n",
       "      <td>-0.009</td>\n",
       "      <td>-0.190</td>\n",
       "      <td>-0.567</td>\n",
       "      <td>0.388</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.148</td>\n",
       "      <td>0.489</td>\n",
       "      <td>-0.247</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.122</td>\n",
       "      <td>-0.201</td>\n",
       "      <td>0.487</td>\n",
       "      <td>0.493</td>\n",
       "      <td>-0.127</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.443</td>\n",
       "      <td>0.047</td>\n",
       "      <td>0.560</td>\n",
       "      <td>0.176</td>\n",
       "      <td>0.551</td>\n",
       "      <td>0.046</td>\n",
       "      <td>-0.220</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.294</td>\n",
       "      <td>0.104</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-0.166</td>\n",
       "      <td>-0.062</td>\n",
       "      <td>-0.311</td>\n",
       "      <td>0.046</td>\n",
       "      <td>-0.055</td>\n",
       "      <td>0.063</td>\n",
       "      <td>0.485</td>\n",
       "      <td>0.493</td>\n",
       "      <td>-0.227</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.458</td>\n",
       "      <td>-0.398</td>\n",
       "      <td>0.101</td>\n",
       "      <td>0.199</td>\n",
       "      <td>0.634</td>\n",
       "      <td>0.017</td>\n",
       "      <td>-0.234</td>\n",
       "      <td>0.008</td>\n",
       "      <td>0.373</td>\n",
       "      <td>0.569</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.102</td>\n",
       "      <td>0.294</td>\n",
       "      <td>-0.259</td>\n",
       "      <td>0.051</td>\n",
       "      <td>-0.183</td>\n",
       "      <td>0.148</td>\n",
       "      <td>0.474</td>\n",
       "      <td>0.504</td>\n",
       "      <td>0.010</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.456</td>\n",
       "      <td>-0.398</td>\n",
       "      <td>1.007</td>\n",
       "      <td>0.137</td>\n",
       "      <td>1.042</td>\n",
       "      <td>-0.040</td>\n",
       "      <td>-0.290</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.666</td>\n",
       "      <td>0.391</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.300</td>\n",
       "      <td>0.428</td>\n",
       "      <td>0.208</td>\n",
       "      <td>0.051</td>\n",
       "      <td>-0.033</td>\n",
       "      <td>0.116</td>\n",
       "      <td>0.408</td>\n",
       "      <td>0.497</td>\n",
       "      <td>0.155</td>\n",
       "      <td>0.904</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.458</td>\n",
       "      <td>-0.776</td>\n",
       "      <td>0.291</td>\n",
       "      <td>0.370</td>\n",
       "      <td>0.181</td>\n",
       "      <td>-0.040</td>\n",
       "      <td>-0.290</td>\n",
       "      <td>0.008</td>\n",
       "      <td>-0.140</td>\n",
       "      <td>-0.497</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1920</th>\n",
       "      <td>-1.362</td>\n",
       "      <td>-1.553</td>\n",
       "      <td>-3.096</td>\n",
       "      <td>-0.444</td>\n",
       "      <td>0.381</td>\n",
       "      <td>1.375</td>\n",
       "      <td>-4.854</td>\n",
       "      <td>-5.331</td>\n",
       "      <td>-4.074</td>\n",
       "      <td>-3.838</td>\n",
       "      <td>...</td>\n",
       "      <td>0.525</td>\n",
       "      <td>0.171</td>\n",
       "      <td>-4.488</td>\n",
       "      <td>-5.793</td>\n",
       "      <td>-4.050</td>\n",
       "      <td>-1.187</td>\n",
       "      <td>-0.852</td>\n",
       "      <td>-2.131</td>\n",
       "      <td>-2.564</td>\n",
       "      <td>0.597</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1921</th>\n",
       "      <td>-2.698</td>\n",
       "      <td>-3.452</td>\n",
       "      <td>-3.620</td>\n",
       "      <td>-1.066</td>\n",
       "      <td>-1.385</td>\n",
       "      <td>1.378</td>\n",
       "      <td>-4.927</td>\n",
       "      <td>-5.103</td>\n",
       "      <td>-4.393</td>\n",
       "      <td>-1.683</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.446</td>\n",
       "      <td>1.297</td>\n",
       "      <td>-0.613</td>\n",
       "      <td>-7.698</td>\n",
       "      <td>-0.674</td>\n",
       "      <td>-1.187</td>\n",
       "      <td>-0.852</td>\n",
       "      <td>-2.131</td>\n",
       "      <td>-2.564</td>\n",
       "      <td>1.215</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1922</th>\n",
       "      <td>-2.615</td>\n",
       "      <td>-3.564</td>\n",
       "      <td>-3.402</td>\n",
       "      <td>-0.422</td>\n",
       "      <td>-1.272</td>\n",
       "      <td>1.121</td>\n",
       "      <td>-4.223</td>\n",
       "      <td>-4.315</td>\n",
       "      <td>-5.196</td>\n",
       "      <td>-3.407</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>0.552</td>\n",
       "      <td>0.125</td>\n",
       "      <td>-6.111</td>\n",
       "      <td>0.275</td>\n",
       "      <td>-1.851</td>\n",
       "      <td>-1.548</td>\n",
       "      <td>-1.537</td>\n",
       "      <td>-2.544</td>\n",
       "      <td>1.612</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1923</th>\n",
       "      <td>-2.661</td>\n",
       "      <td>-3.646</td>\n",
       "      <td>-3.271</td>\n",
       "      <td>-0.699</td>\n",
       "      <td>-1.270</td>\n",
       "      <td>1.116</td>\n",
       "      <td>-3.716</td>\n",
       "      <td>-3.809</td>\n",
       "      <td>-4.735</td>\n",
       "      <td>-2.976</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.447</td>\n",
       "      <td>0.318</td>\n",
       "      <td>1.086</td>\n",
       "      <td>-5.268</td>\n",
       "      <td>0.683</td>\n",
       "      <td>-1.645</td>\n",
       "      <td>-1.471</td>\n",
       "      <td>-1.537</td>\n",
       "      <td>-2.549</td>\n",
       "      <td>1.431</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1924</th>\n",
       "      <td>-2.321</td>\n",
       "      <td>-3.037</td>\n",
       "      <td>-3.214</td>\n",
       "      <td>-1.594</td>\n",
       "      <td>-0.910</td>\n",
       "      <td>1.259</td>\n",
       "      <td>-3.616</td>\n",
       "      <td>-3.747</td>\n",
       "      <td>-4.368</td>\n",
       "      <td>-2.976</td>\n",
       "      <td>...</td>\n",
       "      <td>-0.442</td>\n",
       "      <td>0.323</td>\n",
       "      <td>-0.774</td>\n",
       "      <td>-5.211</td>\n",
       "      <td>1.618</td>\n",
       "      <td>-1.703</td>\n",
       "      <td>-1.471</td>\n",
       "      <td>-1.537</td>\n",
       "      <td>-1.123</td>\n",
       "      <td>1.988</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>1925 rows × 38 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V2     V3     V4     V5     V6     V7     V8     V9  \\\n",
       "0     0.368  0.380 -0.225 -0.049  0.379  0.092  0.550  0.551  0.244  0.904   \n",
       "1     0.148  0.489 -0.247 -0.049  0.122 -0.201  0.487  0.493 -0.127  0.904   \n",
       "2    -0.166 -0.062 -0.311  0.046 -0.055  0.063  0.485  0.493 -0.227  0.904   \n",
       "3     0.102  0.294 -0.259  0.051 -0.183  0.148  0.474  0.504  0.010  0.904   \n",
       "4     0.300  0.428  0.208  0.051 -0.033  0.116  0.408  0.497  0.155  0.904   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "1920 -1.362 -1.553 -3.096 -0.444  0.381  1.375 -4.854 -5.331 -4.074 -3.838   \n",
       "1921 -2.698 -3.452 -3.620 -1.066 -1.385  1.378 -4.927 -5.103 -4.393 -1.683   \n",
       "1922 -2.615 -3.564 -3.402 -0.422 -1.272  1.121 -4.223 -4.315 -5.196 -3.407   \n",
       "1923 -2.661 -3.646 -3.271 -0.699 -1.270  1.116 -3.716 -3.809 -4.735 -2.976   \n",
       "1924 -2.321 -3.037 -3.214 -1.594 -0.910  1.259 -3.616 -3.747 -4.368 -2.976   \n",
       "\n",
       "      ...    V28    V29    V30    V31    V32    V33    V34    V35    V36  \\\n",
       "0     ... -0.449  0.047  0.057 -0.042  0.847  0.534 -0.009 -0.190 -0.567   \n",
       "1     ... -0.443  0.047  0.560  0.176  0.551  0.046 -0.220  0.008 -0.294   \n",
       "2     ... -0.458 -0.398  0.101  0.199  0.634  0.017 -0.234  0.008  0.373   \n",
       "3     ... -0.456 -0.398  1.007  0.137  1.042 -0.040 -0.290  0.008 -0.666   \n",
       "4     ... -0.458 -0.776  0.291  0.370  0.181 -0.040 -0.290  0.008 -0.140   \n",
       "...   ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "1920  ...  0.525  0.171 -4.488 -5.793 -4.050 -1.187 -0.852 -2.131 -2.564   \n",
       "1921  ... -0.446  1.297 -0.613 -7.698 -0.674 -1.187 -0.852 -2.131 -2.564   \n",
       "1922  ... -0.447  0.552  0.125 -6.111  0.275 -1.851 -1.548 -1.537 -2.544   \n",
       "1923  ... -0.447  0.318  1.086 -5.268  0.683 -1.645 -1.471 -1.537 -2.549   \n",
       "1924  ... -0.442  0.323 -0.774 -5.211  1.618 -1.703 -1.471 -1.537 -1.123   \n",
       "\n",
       "        V37  \n",
       "0     0.388  \n",
       "1     0.104  \n",
       "2     0.569  \n",
       "3     0.391  \n",
       "4    -0.497  \n",
       "...     ...  \n",
       "1920  0.597  \n",
       "1921  1.215  \n",
       "1922  1.612  \n",
       "1923  1.431  \n",
       "1924  1.988  \n",
       "\n",
       "[1925 rows x 38 columns]"
      ]
     },
     "execution_count": 50,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "real_test = pd.read_csv('zhengqi_test.txt',sep='\\t')\n",
    "real_test"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 52,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>V0</th>\n",
       "      <th>V1</th>\n",
       "      <th>V8</th>\n",
       "      <th>V27</th>\n",
       "      <th>V31</th>\n",
       "      <th>V2</th>\n",
       "      <th>V3</th>\n",
       "      <th>V37</th>\n",
       "      <th>V20</th>\n",
       "      <th>V10</th>\n",
       "      <th>V5</th>\n",
       "      <th>V24</th>\n",
       "      <th>V13</th>\n",
       "      <th>V19</th>\n",
       "      <th>V18</th>\n",
       "      <th>V30</th>\n",
       "      <th>V22</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.368</td>\n",
       "      <td>0.380</td>\n",
       "      <td>0.244</td>\n",
       "      <td>0.208</td>\n",
       "      <td>-0.042</td>\n",
       "      <td>-0.225</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.388</td>\n",
       "      <td>-0.252</td>\n",
       "      <td>-0.419</td>\n",
       "      <td>0.092</td>\n",
       "      <td>-1.314</td>\n",
       "      <td>-0.114</td>\n",
       "      <td>0.899</td>\n",
       "      <td>0.247</td>\n",
       "      <td>0.057</td>\n",
       "      <td>-0.063</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>0.148</td>\n",
       "      <td>0.489</td>\n",
       "      <td>-0.127</td>\n",
       "      <td>0.226</td>\n",
       "      <td>0.176</td>\n",
       "      <td>-0.247</td>\n",
       "      <td>-0.049</td>\n",
       "      <td>0.104</td>\n",
       "      <td>-0.276</td>\n",
       "      <td>-0.403</td>\n",
       "      <td>-0.201</td>\n",
       "      <td>-1.310</td>\n",
       "      <td>0.653</td>\n",
       "      <td>1.168</td>\n",
       "      <td>0.073</td>\n",
       "      <td>0.560</td>\n",
       "      <td>-0.063</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>-0.166</td>\n",
       "      <td>-0.062</td>\n",
       "      <td>-0.227</td>\n",
       "      <td>0.084</td>\n",
       "      <td>0.199</td>\n",
       "      <td>-0.311</td>\n",
       "      <td>0.046</td>\n",
       "      <td>0.569</td>\n",
       "      <td>-0.340</td>\n",
       "      <td>0.330</td>\n",
       "      <td>0.063</td>\n",
       "      <td>-1.310</td>\n",
       "      <td>0.398</td>\n",
       "      <td>0.980</td>\n",
       "      <td>0.070</td>\n",
       "      <td>0.101</td>\n",
       "      <td>-0.063</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>0.102</td>\n",
       "      <td>0.294</td>\n",
       "      <td>0.010</td>\n",
       "      <td>0.203</td>\n",
       "      <td>0.137</td>\n",
       "      <td>-0.259</td>\n",
       "      <td>0.051</td>\n",
       "      <td>0.391</td>\n",
       "      <td>-0.292</td>\n",
       "      <td>-0.431</td>\n",
       "      <td>0.148</td>\n",
       "      <td>0.234</td>\n",
       "      <td>-0.340</td>\n",
       "      <td>1.070</td>\n",
       "      <td>0.078</td>\n",
       "      <td>1.007</td>\n",
       "      <td>0.133</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.300</td>\n",
       "      <td>0.428</td>\n",
       "      <td>0.155</td>\n",
       "      <td>0.227</td>\n",
       "      <td>0.370</td>\n",
       "      <td>0.208</td>\n",
       "      <td>0.051</td>\n",
       "      <td>-0.497</td>\n",
       "      <td>-0.150</td>\n",
       "      <td>-0.162</td>\n",
       "      <td>0.116</td>\n",
       "      <td>0.237</td>\n",
       "      <td>0.611</td>\n",
       "      <td>1.238</td>\n",
       "      <td>0.080</td>\n",
       "      <td>0.291</td>\n",
       "      <td>0.133</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1920</th>\n",
       "      <td>-1.362</td>\n",
       "      <td>-1.553</td>\n",
       "      <td>-4.074</td>\n",
       "      <td>-1.674</td>\n",
       "      <td>-5.793</td>\n",
       "      <td>-3.096</td>\n",
       "      <td>-0.444</td>\n",
       "      <td>0.597</td>\n",
       "      <td>-0.088</td>\n",
       "      <td>-2.551</td>\n",
       "      <td>1.375</td>\n",
       "      <td>-0.630</td>\n",
       "      <td>0.928</td>\n",
       "      <td>0.107</td>\n",
       "      <td>-3.573</td>\n",
       "      <td>-4.488</td>\n",
       "      <td>2.953</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1921</th>\n",
       "      <td>-2.698</td>\n",
       "      <td>-3.452</td>\n",
       "      <td>-4.393</td>\n",
       "      <td>-1.773</td>\n",
       "      <td>-7.698</td>\n",
       "      <td>-3.620</td>\n",
       "      <td>-1.066</td>\n",
       "      <td>1.215</td>\n",
       "      <td>-0.506</td>\n",
       "      <td>-2.525</td>\n",
       "      <td>1.378</td>\n",
       "      <td>-0.204</td>\n",
       "      <td>1.871</td>\n",
       "      <td>0.193</td>\n",
       "      <td>-0.965</td>\n",
       "      <td>-0.613</td>\n",
       "      <td>3.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1922</th>\n",
       "      <td>-2.615</td>\n",
       "      <td>-3.564</td>\n",
       "      <td>-5.196</td>\n",
       "      <td>-1.585</td>\n",
       "      <td>-6.111</td>\n",
       "      <td>-3.402</td>\n",
       "      <td>-0.422</td>\n",
       "      <td>1.612</td>\n",
       "      <td>0.109</td>\n",
       "      <td>-2.529</td>\n",
       "      <td>1.121</td>\n",
       "      <td>1.057</td>\n",
       "      <td>1.976</td>\n",
       "      <td>0.301</td>\n",
       "      <td>-1.568</td>\n",
       "      <td>0.125</td>\n",
       "      <td>3.511</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1923</th>\n",
       "      <td>-2.661</td>\n",
       "      <td>-3.646</td>\n",
       "      <td>-4.735</td>\n",
       "      <td>-1.410</td>\n",
       "      <td>-5.268</td>\n",
       "      <td>-3.271</td>\n",
       "      <td>-0.699</td>\n",
       "      <td>1.431</td>\n",
       "      <td>-1.015</td>\n",
       "      <td>-2.560</td>\n",
       "      <td>1.116</td>\n",
       "      <td>0.800</td>\n",
       "      <td>1.520</td>\n",
       "      <td>-0.036</td>\n",
       "      <td>-1.282</td>\n",
       "      <td>1.086</td>\n",
       "      <td>3.511</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1924</th>\n",
       "      <td>-2.321</td>\n",
       "      <td>-3.037</td>\n",
       "      <td>-4.368</td>\n",
       "      <td>-1.242</td>\n",
       "      <td>-5.211</td>\n",
       "      <td>-3.214</td>\n",
       "      <td>-1.594</td>\n",
       "      <td>1.988</td>\n",
       "      <td>-1.502</td>\n",
       "      <td>0.056</td>\n",
       "      <td>1.259</td>\n",
       "      <td>0.799</td>\n",
       "      <td>0.847</td>\n",
       "      <td>0.592</td>\n",
       "      <td>-1.213</td>\n",
       "      <td>-0.774</td>\n",
       "      <td>3.609</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>1925 rows × 17 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "         V0     V1     V8    V27    V31     V2     V3    V37    V20    V10  \\\n",
       "0     0.368  0.380  0.244  0.208 -0.042 -0.225 -0.049  0.388 -0.252 -0.419   \n",
       "1     0.148  0.489 -0.127  0.226  0.176 -0.247 -0.049  0.104 -0.276 -0.403   \n",
       "2    -0.166 -0.062 -0.227  0.084  0.199 -0.311  0.046  0.569 -0.340  0.330   \n",
       "3     0.102  0.294  0.010  0.203  0.137 -0.259  0.051  0.391 -0.292 -0.431   \n",
       "4     0.300  0.428  0.155  0.227  0.370  0.208  0.051 -0.497 -0.150 -0.162   \n",
       "...     ...    ...    ...    ...    ...    ...    ...    ...    ...    ...   \n",
       "1920 -1.362 -1.553 -4.074 -1.674 -5.793 -3.096 -0.444  0.597 -0.088 -2.551   \n",
       "1921 -2.698 -3.452 -4.393 -1.773 -7.698 -3.620 -1.066  1.215 -0.506 -2.525   \n",
       "1922 -2.615 -3.564 -5.196 -1.585 -6.111 -3.402 -0.422  1.612  0.109 -2.529   \n",
       "1923 -2.661 -3.646 -4.735 -1.410 -5.268 -3.271 -0.699  1.431 -1.015 -2.560   \n",
       "1924 -2.321 -3.037 -4.368 -1.242 -5.211 -3.214 -1.594  1.988 -1.502  0.056   \n",
       "\n",
       "         V5    V24    V13    V19    V18    V30    V22  \n",
       "0     0.092 -1.314 -0.114  0.899  0.247  0.057 -0.063  \n",
       "1    -0.201 -1.310  0.653  1.168  0.073  0.560 -0.063  \n",
       "2     0.063 -1.310  0.398  0.980  0.070  0.101 -0.063  \n",
       "3     0.148  0.234 -0.340  1.070  0.078  1.007  0.133  \n",
       "4     0.116  0.237  0.611  1.238  0.080  0.291  0.133  \n",
       "...     ...    ...    ...    ...    ...    ...    ...  \n",
       "1920  1.375 -0.630  0.928  0.107 -3.573 -4.488  2.953  \n",
       "1921  1.378 -0.204  1.871  0.193 -0.965 -0.613  3.149  \n",
       "1922  1.121  1.057  1.976  0.301 -1.568  0.125  3.511  \n",
       "1923  1.116  0.800  1.520 -0.036 -1.282  1.086  3.511  \n",
       "1924  1.259  0.799  0.847  0.592 -1.213 -0.774  3.609  \n",
       "\n",
       "[1925 rows x 17 columns]"
      ]
     },
     "execution_count": 52,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "real_test1 = real_test[test_numi]\n",
    "real_test1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 53,
   "metadata": {},
   "outputs": [],
   "source": [
    "np.savetxt('..\\\\predict1.txt',m2.predict(real_test1))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 81,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "GridSearchCV(cv=5, error_score=nan,\n",
       "             estimator=GradientBoostingRegressor(alpha=0.9, ccp_alpha=0.0,\n",
       "                                                 criterion='friedman_mse',\n",
       "                                                 init=None, learning_rate=0.1,\n",
       "                                                 loss='ls', max_depth=3,\n",
       "                                                 max_features=None,\n",
       "                                                 max_leaf_nodes=None,\n",
       "                                                 min_impurity_decrease=0.0,\n",
       "                                                 min_impurity_split=None,\n",
       "                                                 min_samples_leaf=31,\n",
       "                                                 min_samples_split=116,\n",
       "                                                 min_weight_fraction_leaf=0.0,\n",
       "                                                 n_estimators=100,\n",
       "                                                 n_iter_no_change=None,\n",
       "                                                 presort='deprecated',\n",
       "                                                 random_state=None,\n",
       "                                                 subsample=1.0, tol=0.0001,\n",
       "                                                 validation_fraction=0.1,\n",
       "                                                 verbose=0, warm_start=False),\n",
       "             iid='deprecated', n_jobs=None,\n",
       "             param_grid={'max_features': range(5, 18)}, pre_dispatch='2*n_jobs',\n",
       "             refit=True, return_train_score=False,\n",
       "             scoring='neg_mean_squared_error', verbose=0)"
      ]
     },
     "execution_count": 81,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "m_adjust = GradientBoostingRegressor(n_estimators=100,max_depth=3,min_samples_leaf=31,min_samples_split=116)\n",
    "paras = {\n",
    "    'max_features':range(5,18)\n",
    "}\n",
    "g1 = GridSearchCV(m_adjust,paras,scoring='neg_mean_squared_error',cv=5)\n",
    "g1.fit(xtrain,ytrain)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 82,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "({'max_features': 7}, -0.10922038167180714)"
      ]
     },
     "execution_count": 82,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "g1.best_params_,g1.best_score_\n",
    "# ({'min_samples_leaf': 31, 'min_samples_split': 110}, -0.11101933826111118)\n",
    "# ({'min_samples_split': 116}, -0.1108980707137028)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 97,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "MSE_Validate: 0.11620187505610587\n",
      "MSE_Test: 0.18639775326483318\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "(0.9310706001265913, 0.8839655946515654, 0.7902397984569195)"
      ]
     },
     "execution_count": 97,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "#GBDT 调参\n",
    "m3_re = GradientBoostingRegressor(n_estimators=100,max_depth=3,min_samples_leaf=31,min_samples_split=116,max_features=17)\n",
    "m3_re.fit(xtrain,ytrain)\n",
    "print('MSE_Validate:',mean_squared_error(yval,m3_re.predict(xval)))\n",
    "print('MSE_Test:',mean_squared_error(test_target,m3_re.predict(test_paras)))\n",
    "m3_re.score(xtrain,ytrain),m3_re.score(xval,yval),m3_re.score(test_paras,test_target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 98,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "No handles with labels found to put in legend.\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYsAAAD4CAYAAAAdIcpQAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjMsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+AADFEAAAXBUlEQVR4nO3df4yd1YHe8e9TGzCmsUKcIYAN9bAaSgaUOOmVhbLF2i5kYyiKASm7RouEtKsQS1hAUtQ13T+6RVpps0u6+WPJWt7GWqQmdmgCG6vtBlza0v7Bj7kGJ+vBeBkMMYMtPGun0BVge+ynf9zjchlmc975YS6eeT7S1b3vOec9PwT44X3Pe31lm4iIiF/mH/V6AhER8dGXsIiIiKqERUREVCUsIiKiKmERERFVC3s9gdnwyU9+0itWrOj1NC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Q1kvZKGpG0sdfzOd0kbZF0SNLurrJPSNoh6aXyfn4v53i6SLpE0v+QtEfSsKS7S/mcX7+kRZKelfTTsvZ/V8rn/NpPkbRA0vOS/nM5nk9rf1XS30jaJaldyqa8/nkbFpIWAA8C1wODwK2SBns7q9PuL4E1E8o2Ak/YHgCeKMdz0Tjwr2x/GrgauLP8854P6z8K/LrtzwIrgTWSrmZ+rP2Uu4E9Xcfzae0A/8L2yq7vVkx5/fM2LIBVwIjtfbaPAduAtT2e02ll+38BRyYUrwUeKp8fAm76UCf1IbF90PZz5fP/pfMHxzLmwfrd8ffl8KzyMvNg7QCSlgP/EvgPXcXzYu2/xJTXP5/DYhnwWtfxaCmbbz5l+yB0/kAFLujxfE47SSuAzwHPME/WX27D7AIOATtsz5u1A98G/jVwsqtsvqwdOv9j8LiknZLuKGVTXv/C0zjBjzpNUpbniOc4Sf8Y+BFwj+23pMn+NZh7bJ8AVkr6OPCopKt6PacPg6QbgUO2d0r6tV7Pp0d+1fYBSRcAOyS9OJ1O5vOVxShwSdfxcuBAj+bSS29IugigvB/q8XxOG0ln0QmK79l+pBTPm/UD2P4/wP+ks3c1H9b+q8CXJb1K51bzr0v6j8yPtQNg+0B5PwQ8SucW/JTXP5/DYggYkNQv6WxgHbC9x3Pqhe3A7eXz7cCPeziX00adS4jvAnts//uuqjm/fkl95YoCSecC1wEvMg/Wbvs+28ttr6Dz3/h/t30b82DtAJLOk/SxU5+B3wB2M431z+tvcEu6gc79zAXAFtt/2OMpnVaStgK/RuevJ34D+LfAXwEPA5cC+4Gv2J64CX7Gk/TPgf8N/A3v3bv+N3T2Leb0+iV9hs4m5gI6/4P4sO37JS1ljq+9W7kNda/tG+fL2iVdRudqAjrbDt+3/YfTWf+8DouIiGhmPt+GioiIhhIWERFRlbCIiIiqhEVERFQlLCIioiphERERVQmLiIio+n9wqYjaMk6oUgAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 99,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "[0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.1863977532648331,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483318,\n",
       " 0.18639775326483315,\n",
       " 0.18639775326483315]"
      ]
     },
     "execution_count": 99,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "k"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 92,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "max_valid: 0.11597631654115448 \n",
      "max_test: 0.18479703221143487\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAAD4CAYAAADiry33AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjMsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+AADFEAAAgAElEQVR4nO3deXxU5b3H8c8PEgi7rAJBDFoUEFLhRkRpVbSgVAv1llpcWttrK9aqBUuL3KrF6q3WWqptFUtdq1RqKYqtG1oX7L2KBFTKosgiEkCI7Dsh+d0/nsQMYUgmIclJTr7v12tes50585vM5HvOec5znmPujoiIxFejqAsQEZGapaAXEYk5Bb2ISMwp6EVEYk5BLyISc2lRF5BMhw4dPCsrK+oyRETqjfnz53/q7h2TPVcngz4rK4vc3NyoyxARqTfMbPXhnlPTjYhIzCnoRURiTkEvIhJzdbKNXkSkMgoKCsjLy2Pv3r1Rl1LjMjIy6NatG+np6Sm/RkEvIvVeXl4erVq1IisrCzOLupwa4+5s2rSJvLw8evTokfLr1HQjIvXe3r17ad++faxDHsDMaN++faW3XBT0IhILcQ/5ElX5nLEJenf4xS9gwYKoKxERqVtiE/Rbt8L998PIkbBhQ9TViIiUr2XLlgCsW7eOUaNGJZ3mrLPOqpaDR2MT9G3bwqxZsGkTXHgh7NsXdUUiIhXr2rUrM2bMqNH3iE3QA/TvD48+Cm++CVddFZpzRERqw4QJE7jvvvs+uz9p0iRuueUWzjnnHAYMGEC/fv2YNWvWIa/76KOP6Nu3LwB79uxh9OjRZGdn841vfIM9e/ZUS22x61759a/DTTfBrbfC5z8PY8dGXZGI1KqxY+Hdd6t3niefDHffXe4ko0ePZuzYsVx99dUAPPnkk7zwwguMGzeO1q1b8+mnnzJo0CBGjBhx2B2qU6ZMoXnz5ixcuJCFCxcyYMCAaik/dkEPMGkSLFoEP/oR9OkDw4ZFXZGIx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0IiIxp6AXEYk5Bb2ISMwp6EVEYk5BLyIScwp6EZGYU9CLiMTc/wNL8WcI/96KFAAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.figure()\n",
    "plt.plot(range(1,18),k1,color=\"red\",label=\"valid\")\n",
    "plt.plot(range(1,18),k2,color=\"blue\",label=\"test\")\n",
    "# plt.xticks(range(0,18))\n",
    "print('max_valid:',min(k1),'\\nmax_test:',min(k2))\n",
    "plt.legend()\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 100,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1.5002597402597402"
      ]
     },
     "execution_count": 100,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "2888/1925"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 101,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "577.6"
      ]
     },
     "execution_count": 101,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "2888/5"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 103,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1155"
      ]
     },
     "execution_count": 103,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "2888-1733"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.2"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
